package cn.net.yato.picture.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.servlet.ModelAndView;

/**
 * @ClassName SysController
 * @Description
 * @Author yato
 * @Date 2020/2/19 11:36
 * @Version 1.0
 */
@RestController
public class SysController {

    @GetMapping("/403.html")
    public ModelAndView notPermission(ModelAndView modelAndView){
        modelAndView.setViewName("sys/403");
        return modelAndView;
    }

    @GetMapping("/404.html")
    public ModelAndView notFoundError(ModelAndView modelAndView){
        modelAndView.setViewName("sys/404");
        return modelAndView;
    }

    @GetMapping("/500.html")
    public ModelAndView serviceError(ModelAndView modelAndView){
        modelAndView.setViewName("sys/500");
        return modelAndView;
    }

    @GetMapping("/sys/header.html")
    public ModelAndView header(ModelAndView modelAndView){
        modelAndView.setViewName("sys/header");
        return modelAndView;
    }


}
